using CodeSaude.Domain.Entities;
using System.ComponentModel.DataAnnotations;
using System.Data.Entity.ModelConfiguration;

namespace CodeSaude.Infrastructure.Data.EntityConfig
{
    public class boletim_saidaMap : EntityTypeConfiguration<boletim_saida>
    {
        public boletim_saidaMap()
        {
            // Primary Key
            this.HasKey(t => t.id_saida);

            // Properties
            this.Property(t => t.nome_saida)
                .IsRequired()
                .HasMaxLength(45);

            // Table & Column Mappings
            this.ToTable("boletim_saida");
            this.Property(t => t.id_saida).HasColumnName("id_saida");
            this.Property(t => t.nome_saida).HasColumnName("nome_saida");
            this.Property(t => t.data_criacao).HasColumnName("data_criacao");
            this.Property(t => t.Usuario_criacao).HasColumnName("Usuario_criacao");
            this.Property(t => t.data_alteracao).HasColumnName("data_alteracao");
            this.Property(t => t.Usuario_alteracao).HasColumnName("Usuario_alteracao");
        }
    }
}
